﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Invoice_Add.aspx.cs" Inherits="Stock_Invoice_Add" MasterPageFile="../MasterPage.master" %>
<%@ Import Namespace="Common" %>
<%@ Register src="Stock_Left.ascx" tagname="Stock_Left" tagprefix="uc1" %>

<asp:Content runat="server" ContentPlaceHolderID="ContentPlaceHolder1">
    <table cellpadding="0" cellspacing="2" width="100%" border="0">
	<tr>
        <td class="leftTd"  valign="top" width="20%">
            <uc1:Stock_Left ID="Stock_Left1" runat="server" />
        </td>
		<td width="85%" valign="top">
		<table cellpadding="0" cellspacing="0" width="100%" border="0" align="center">
			<tr>
		        <td class="leftTd"  valign="top">
		        <table cellpadding="0" cellspacing="0" width="100%" border="0" align="center">
		        	<tr>
		            	<td class="titleStyle"><%= WebUtility.GetTitleByMenu(MenuType) %></td>
		            </tr>
		        </table>
		        <br />
		        <table cellpadding="0" cellspacing="1" width="100%" border="0" style="background:#000066;">
	                    <tr>
	                        <td class="leftContent">预约序号：</td>
	                        <td class="RightContent">
	                        <asp:TextBox ID="txt_DanNum" runat="server" Width="150px" class="face"></asp:TextBox>
                            <a class="thickbox" href="../Business/SelectDanNum.aspx?ParentID=<%= txt_DanNum.ClientID %>&UserNameID=<%= txt_CustName.ClientID %>&KeepThis=true&TB_iframe=true&height=550&width=800" >选择预约序号</a>
	                            &nbsp; &nbsp;</td>
	                    </tr>
	                    <% if (Convert.ToInt32(Session["UserType"]) == 4) { %>
	                    <tr>
	                        <td class="leftContent">客户名称：</td>
	                        <td class="RightContent">
	                        <asp:TextBox ID="txt_CustName" runat="server" Width="200px" class="face"></asp:TextBox>
	                            <a class="thickbox" href="../Stock/SelectUser.aspx?ParentID=<%= txt_CustName.ClientID %>&KeepThis=true&TB_iframe=true&height=550&width=800" >请选择客户</a>
	                            &nbsp; &nbsp;<asp:RequiredFieldValidator ID="RequiredFieldValidator6" 
                                    runat="server" ControlToValidate="txt_CustName" ErrorMessage="请选择客户"></asp:RequiredFieldValidator>
                            </td>
	                    </tr>
	                    <tr>
	                        <td class="leftContent">开票日期：</td>
	                        <td class="RightContent">
	                        <asp:TextBox ID="txt_InvoiceDate" runat="server" Width="80px" class="face"></asp:TextBox>
	                            <asp:RequiredFieldValidator ID="RequiredFieldValidator3" 
                                    runat="server" ControlToValidate="txt_InvoiceDate" ErrorMessage="请选择发票日期"></asp:RequiredFieldValidator>
	                        </td>
	                    </tr>
	                     <tr>
	                        <td class="leftContent">发票号码：</td>
	                        <td class="RightContent">
	                        <asp:TextBox ID="txt_InvoiceNO" runat="server" Width="150px" class="face"></asp:TextBox>
	                            &nbsp; &nbsp;<asp:RequiredFieldValidator ID="RequiredFieldValidator4" 
                                    runat="server" ControlToValidate="txt_InvoiceNO" ErrorMessage="请填写发票号码"></asp:RequiredFieldValidator>
	                         </td>
	                    </tr>
	                     <tr>
	                        <td class="leftContent">发票内容：</td>
	                        <td class="RightContent">
	                        <asp:TextBox ID="txt_InvoiceContent" runat="server" Width="308px" class="face" Height="64px" 
                                    TextMode="MultiLine"></asp:TextBox>
	                            &nbsp; &nbsp;</td>
	                    </tr>
	                    <tr>
	                        <td class="leftContent">金额：</td>
	                        <td class="RightContent">
	                        <asp:TextBox ID="txt_InvoicePrice" runat="server" Width="80px" class="face"></asp:TextBox>
	                            <asp:RequiredFieldValidator ID="RequiredFieldValidator1" 
                                    runat="server" ControlToValidate="txt_InvoicePrice" ErrorMessage="请填写单价" 
                                    Display="Dynamic"></asp:RequiredFieldValidator>
	                            <asp:CompareValidator ID="CompareValidator2" runat="server" 
                                    ControlToValidate="txt_InvoicePrice" ErrorMessage="单价是大于0的数字" Operator="GreaterThan" 
                                    Type="Currency" ValueToCompare="0"></asp:CompareValidator>
	                        </td>
	                    </tr>
	                     <tr>
	                        <td class="leftContent">送达日期：</td>
	                        <td class="RightContent">
	                        <asp:TextBox ID="txt_ArriveDate" runat="server" Width="80px" class="face"></asp:TextBox>
	                        </td>
	                    </tr>
	                     <tr>
	                        <td class="leftContent">经手人：</td>
	                        <td class="RightContent">
	                         <asp:DropDownList ID="txt_MUserKey" runat="server" CssClass="face">
		                        <asp:ListItem Value="" Selected="True">请指定经手人</asp:ListItem>
		                      </asp:DropDownList>
	                            <asp:RequiredFieldValidator ID="RequiredFieldValidator5" 
                                    runat="server" ControlToValidate="txt_MUserKey" ErrorMessage="选择经手人" 
                                    Display="Dynamic"></asp:RequiredFieldValidator>
	                            </td>
	                    </tr>
	                    <% } %>
	                     <tr>
	                        <td class="leftContent" valign="top" style="padding-top:20px;height:30px;"></td>
	                        <td class="RightContent">
                            <asp:Button ID="btnSubmit" runat="server" Text="添 加" CssClass="button" 
                                    onclick="btnSubmit_Click" />
	                        &nbsp;&nbsp;&nbsp;&nbsp;<input type="reset" value="重 置" name="btnReset" class="button"></td>
	                    </tr>
	                </table>
				</td>
		    </tr>
		</table>
        </td>
    </tr>
</table>
</asp:Content>

